for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
import { HtmlColumn } from './HtmlColumn';
type IColumn = string | HtmlColumn;
export interface ICell {
name: string;
renderHtml(): string;
renderText(): string;
}
export type Row = ICell[];
export class Table {
constructor(
public readonly columns: IColumn[],
public readonly rows: Row[]
) {}
public getColumnTexts(): string[] {
return this.columns.map(col =>
col instanceof HtmlColumn ? col.text : col
);
export class Inline {
constructor(public readonly columns: IColumn[], public readonly row: Row) {}